sw: insert image: set anchor to at-char by default

This changes the default set in commit
4f40bf6a79de6d60da0a5090cdfeda6242e889f0 (sw: insert image: set anchor
to as-char by default, 2019-07-04), to have a better compromise, taking
both Word defaults compatibility and usability into account.

The problem is that users are used to just inserting an image and being
able to drag it to its final location, which is broken with as-char
anchoring.

So default to at-char anchoring, this is still something that is fully
interoperable to Word (unlike the old to-para anchoring), but allows the
easier image move again.

(cherry picked from commit a7528cd6f17ea5c5b29e7d607e54c62de0d9e7db)

[ See the discussion at the end of
<https://gerrit.libreoffice.org/#/c/75091/> for the motivation of this
backport. ]

Change-Id: Ibc61ae167fc9e5cc31b04c83e854556309e27fd4
Reviewed-on: https://gerrit.libreoffice.org/84513
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
diff --git a/sw/qa/extras/unowriter/unowriter.cxx b/sw/qa/extras/unowriter/unowriter.cxx
index 577a4b5..630a72a 100644
--- a/sw/qa/extras/unowriter/unowriter.cxx
+++ b/sw/qa/extras/unowriter/unowriter.cxx
@@ -624,7 +624,7 @@
    RndStdIds eFlyAnchor = pFlyFormat->GetAnchor().GetAnchorId();
    // Without the working image listener in place, this test would have
    // failed, eFlyAnchor was FLY_AT_PARA.
    CPPUNIT_ASSERT_EQUAL(RndStdIds::FLY_AS_CHAR, eFlyAnchor);
    CPPUNIT_ASSERT_EQUAL(RndStdIds::FLY_AT_CHAR, eFlyAnchor);

    pTransfer->Cut();
    pListener->GetString().clear();
diff --git a/sw/source/uibase/frmdlg/frmmgr.cxx b/sw/source/uibase/frmdlg/frmmgr.cxx
index 5894fa7..e09d426 100644
--- a/sw/source/uibase/frmdlg/frmmgr.cxx
+++ b/sw/source/uibase/frmdlg/frmmgr.cxx
@@ -88,7 +88,7 @@

        if (nType == Frmmgr_Type::GRF || nType == Frmmgr_Type::OLE)
        {
            m_aSet.Put(SwFormatAnchor(RndStdIds::FLY_AS_CHAR));
            m_aSet.Put(SwFormatAnchor(RndStdIds::FLY_AT_CHAR));
        }
    }
    else if ( nType == Frmmgr_Type::NONE )